package com.itheima.config;


import org.springframework.context.annotation.ComponentScan;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.annotation.FilterType;
import org.springframework.web.servlet.config.annotation.DefaultServletHandlerConfigurer;
import org.springframework.web.servlet.config.annotation.EnableWebMvc;
import org.springframework.web.servlet.config.annotation.WebMvcConfigurer;
import org.springframework.stereotype.Controller;

/**
 * @Author: Administrator
 * @Name; xqf
 * @Date: 2021/2/21 19:57
 */
@Configuration
@ComponentScan(value = "com.itheima", includeFilters =
@ComponentScan.Filter(type = FilterType.ANNOTATION, classes = {Controller.class})
)
@EnableWebMvc
public class SpringMVCConfiguration implements WebMvcConfigurer {

    @Override
    public void configureDefaultServletHandling(DefaultServletHandlerConfigurer configurer) {
        configurer.enable();
    }
}
